package com.ym.medical.domain.param;

import com.ym.common.annotations.CustomConstraint;
import com.ym.common.constant.BeanCovert;
import com.ym.base.enums.FlagEnum;
import com.ym.medical.domain.entity.StudioPersonnelEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.util.Date;

import static com.ym.common.constant.ValidRule.Add;
import static com.ym.common.constant.ValidRule.Update;

/**
 * 工作室成员对象 studio_personnel
 *
 * @author ym
 * @date 2020-08-21
 */
@ApiModel("工作室成员-修改")
@Builder
@Data
@AllArgsConstructor
@NoArgsConstructor
public class StudioPersonnelUpdateParam extends BeanCovert<StudioPersonnelEntity> {

	@ApiModelProperty("主键")
	@NotNull(message = "主键不能为空", groups = {Add.class, Update.class})
	private Long id;

	@ApiModelProperty("工作室主键")
	private Long dsId;

	@ApiModelProperty("医生主键")
	private Long doctId;

	@ApiModelProperty("接诊状态(医生) --自己关闭接诊状态")
	@Size(max = 2, message = "接诊状态长度超过{max}", groups = {Add.class, Update.class})
	private String admsStateDoctor;

	@ApiModelProperty("接诊状态(工作室)--工作室关闭医生接诊状态")
	@Size(max = 2, message = "接诊状态长度超过{max}", groups = {Add.class, Update.class})
	private String admsStateStudio;

	@ApiModelProperty("本人、助理、普通成员")
	@Size(max = 2, message = "本人、助理、普通成员长度超过{max}", groups = {Add.class, Update.class})
	private String relType;

	@ApiModelProperty("是否优先派单")
	@Size(max = 2, message = "是否优先派单长度超过{max}", groups = {Add.class, Update.class})
	private String isPriorityOrder;

	@ApiModelProperty("是否置顶")
	@Size(max = 2, message = "是否置顶长度超过{max}", groups = {Add.class, Update.class})
	private String isTop;

	@ApiModelProperty("是否自动留言")
	@Size(max = 2, message = "是否自动留言长度超过{max}", groups = {Add.class, Update.class})
	private String isAutoReply;

	@ApiModelProperty("留言内容")
	@Size(max = 500, message = "留言内容长度超过{max}", groups = {Add.class, Update.class})
	private String spMessage;

	@ApiModelProperty("创建时间")
	private Date createTime;

	@ApiModelProperty("修改时间")
	private Date updateTime;

	@ApiModelProperty("删除标识")
	@Size(max = 2, message = "删除标识长度超过{max}", groups = {Add.class, Update.class})
	@CustomConstraint(FlagEnum.class)
	private String deleted;

}
